<!-- 导航栏的我的书架  -->
<template>
  <div class="myShelf" v-show="$store.getters.getUserInfo.username" @click="myShelfClick" v-cloak>我的书架</div>
</template>

<script>
import { defineComponent } from "vue";
import { useRouter } from "vue-router";

export default defineComponent({
  setup() {
    const router = useRouter()
    
    const myShelfClick = () => {
      router.push("/bookshelf")
    }
    
    return {
      myShelfClick,
    }
  }
})
</script>

<style scoped>
.myShelf {
  position: absolute;
  right: 100px;
  top: 20px;
  cursor: pointer;
}
</style>
